youku.Structure = [
    {
        text: '主客户端',
        cls: 'launchscreen',
        items: [
            {
                text: '基本统计',
                card: demos.Buttons,
                source: 'src/demos/buttons.js',
                leaf: true
            },
            {
                text: '平台详情',
                card: demos.Forms,
                source: 'src/demos/forms.js',
                leaf: true
            }
		]
	},
    {
        text: '厂商内置',
		card: demos.Buttons,
		source: 'src/demos/buttons.js',
		leaf: true
	},
    {
        text: '渠道推广',
		card: demos.Buttons,
		source: 'src/demos/buttons.js',
		leaf: true
	},
    {
        text: 'Paike',
        cls: 'launchscreen',
        items: [
            {
                text: '基本统计',
                card: demos.Buttons,
                source: 'src/demos/buttons.js',
                leaf: true
            },
            {
                text: '平台详情',
                card: demos.Forms,
                source: 'src/demos/forms.js',
                leaf: true
            }
		]
	},
];


Ext.regModel('Demo', {
    fields: [
        {name: 'text',        type: 'string'},
        {name: 'source',      type: 'string'},
        {name: 'preventHide', type: 'boolean'},
        {name: 'cardSwitchAnimation'},
        {name: 'card'}
    ]
});

youku.StructureStore = new Ext.data.TreeStore({
    model: 'Demo',
    root: {
        items: youku.Structure
    },
    proxy: {
        type: 'ajax',
        reader: {
            type: 'tree',
            root: 'items'
        }
    }
});
